import java.util.*;
import java.io.*;
public class test {
    public static PrintWriter pr = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    public static Read in = new Read();
    // 牛客 乒乓球筐
    public static void main(String[] args) throws IOException{
        String s1 = in.next();
        String s2 = in.next();
        char[] a1 = s1.toCharArray();
        char[] a2 = s2.toCharArray();
        int len1 = a1.length;
        int len2 = a2.length;
        HashMap<Character, Integer> map1 = new HashMap<>();
        HashMap<Character, Integer> map2 = new HashMap<>();
        for(int i = 0;i < len1;i++) {
            char c = a1[i];
            map1.put(c, map1.getOrDefault(c, 0) + 1);
        }
        for(int i = 0;i < len2;i++) {
            char c = a2[i];
            map2.put(c, map2.getOrDefault(c, 0) + 1);
        }
        if(map1.size() < map2.size()) {
            System.out.println("No");
            return;
        }
        for(char i = 'A';i <= 'Z';i++) {
            if(map1.getOrDefault(i, 0) < map2.getOrDefault(i, 0)) {
                System.out.println("No");
                return;
            }
        }
        System.out.println("Yes");
    }
    // 牛客 组队竞赛
    public static void main1(String[] args) throws IOException{
// 3*n个选手
// n个队伍,每个队伍3人
// 队伍的水平值 = 该队成员中第二高水平值
// 5 2 8 5 1 5 -> 1 2 5 5 5 8
        int n = in.nextInt();
        n *= 3;
        int[] arr = new int[n + 1];
        for(int i = 1;i <= n;i++) {
            arr[i] = in.nextInt();
        }
        Arrays.sort(arr);
        int left = 1;
        int right = n - 1;
        long sum = 0;
// 1 2 3 4 5 6 7 8 9
        while(left < right) {
            sum += arr[right];
            right -= 2;
            left++;
        }
        System.out.println(sum);
    }
    // 牛客 删除相邻数字最大分数
    public static void main2(String[] args) throws IOException{
        int n = in.nextInt();
        int[] arr = new int[n + 1];
// key:某个数字
// value:数字的数量
        for(int i = 1;i <= n;i++) {
            arr[i] = in.nextInt();
        }
        Arrays.sort(arr);
        HashMap<Integer, Integer> map = new HashMap<>();
        for(int i = 1;i <= n;i++) {
            map.put(arr[i], map.getOrDefault(arr[i], 0) + 1);
        }
        int[] numbers = new int[map.size() + 1];
// 9
// 1 2 1 3 2 2 2 2 3 -> 1 1 2 2 2 2 2 3 3
// 2 5 2
// 每次选择任意一个元素ai
// 数组中 ai-1 和 ai+1 的元素都被删除
// 获得ai分
        int index = 1;
        for(Map.Entry<Integer, Integer> s : map.entrySet()) {
            numbers[index++] = s.getKey();
        }
// numbers = [1,2,3];
        int len = map.size();
//代表选取第i个元素时,此时最大的值
//[][0]代表选
//[][1]代表不选
        int[][] dp = new int[len + 1][2];
        dp[1][0] = numbers[1] * map.get(numbers[1]);
        dp[1][1] = 0;
        for(int i = 2;i <= len;i++) {
//由上一个不选+当前的数字 或者 上一个选
            dp[i][0] = Math.max(dp[i-1][1] + map.get(numbers[i]) * numbers[i], dp[i-1][0]);
            if(numbers[i] != numbers[i - 1] + 1) {
                dp[i][0] = Math.max(dp[i][0], dp[i-1][0] + map.get(numbers[i]) * numbers[i]);
            }
//由上一个选 或者 上一个不选
            dp[i][1] = Math.max(dp[i-1][1], dp[i-1][0]);
        }
        System.out.println(Math.max(dp[len][0],dp[len][1]));
    }
}
class Read{
    StringTokenizer st = new StringTokenizer("");
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    String next() throws IOException{
        while(!st.hasMoreTokens()) {
            st = new StringTokenizer(br.readLine());
        }
        return st.nextToken();
    }
    String nextLine() throws IOException{
        return br.readLine();
    }
    int nextInt() throws IOException{
        return Integer.parseInt(next());
    }
    long nextLong() throws IOException{
        return Long.parseLong(next());
    }
    double nextDouble() throws IOException{
        return Double.parseDouble(next());
    }
}